package dao;

import entity.Count;
import org.apache.ibatis.session.SqlSession;

public class CountsDao extends BaseDao {

    public void addCount(String key, Integer value) {
        SqlSession session = sqlSessionFactory.openSession();
        Count count = new Count(key, value);
        try {
            session.insert("Count.insertCount", count);
        } finally {
            session.close();
        }
    }
}
